package com.macro.mall.commission.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import lombok.experimental.Accessors;

import java.time.LocalDateTime;

/**
 * 用户佣金账户
 *
 * @author xuyanjun
 * @date 2019-12-11
 */
@Getter
@Setter
@ToString
@Accessors(chain = true)
@TableName("commission_user_account")
public class UserAccountEntity {

    /**
     * id
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    /**
     * 创建时间
     */
    @TableField(value = "create_time")
    private LocalDateTime createTime;

    /**
     * 最后更新时间
     */
    @TableField(value = "update_time")
    private LocalDateTime updateTime;

    /**
     * 用户id
     */
    @TableField(value = "user_id")
    private Long userId;

    /**
     * 余额(分)
     */
    @TableField(value = "balance")
    private Integer balance;

    /**
     * 累计收益
     */
    @TableField(value = "total")
    private Integer total;

}